package com.l.shirodemo.shiro.factory;

import java.util.LinkedHashMap;

public class FilterChainDefinitionMapBuilder {

     public LinkedHashMap<String,String> buildFilterChainDefinitionMap(){
         LinkedHashMap<String,String> map = new LinkedHashMap<>();
         /*  /login.jsp = anon
                /login = anon
                /reg = anon
                /myshiro/logout = logout
                /user/list = roles[user]
                /admin/list = roles[admin]
                /** = authc  */
         map.put("/login.jsp", "anon");
         map.put("/login","anon");
         map.put("/reg", "anon");
         map.put("/myshiro/logout", "logout");
         map.put("/user/list", "roles[user]");
         map.put("/admin/list", "roles[admin]");
         map.put("/**", "authc");
         return map;
     }

}
